<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:py="http://purl.org/kid/ns#"
    py:extends="'master.kid'">
<head>
<meta content="text/html; charset=utf-8" http-equiv="Content-Type" py:replace="''"/>
<title>${name}</title>
</head>
<body>
    <h1>${name}</h1>

    <span py:if="len(node.names) &gt; 1">
        <b>Also Known as</b>
        ${', '.join(other_name for other_name in node.name != name)}
    </span>

    <h2>Facts</h2>
    <ul>
        <li py:for="fact in node.facts">${XML(str(fact).encode('utf8'))}</li>
    </ul>

    <form action="addFact">
        <input type="hidden" name="node_name" value="${name}" />
        <input type="text" name="text" />
        <input type="submit" value="Add" />
    </form>

    <h2>Referenced By</h2>
    <ul>
        <li py:for="fact in node.referenced_by">
        <a href="${tg.url(str(fact.node.names[0]))}">${str(fact.node.names[0])}</a>
        - ${XML(str(fact))}
        </li>
    </ul>

</body>
</html>
